#ifndef __WAIT_H__
#define __WAIT_H__

#ifdef __cplusplus
extern "C"
{
#endif

#ifdef _WIN32
#include "win_type.h"
typedef struct {
	pthread_cond_t wait;
}wait_t;
#else
#include <pthread.h>
typedef struct {
	pthread_cond_t wait;
	pthread_mutex_t lock;
}wait_t;
#endif


void wait_init(wait_t *);
void wait_complete(wait_t *);
void wait_cancel(wait_t *wait);
void wait_wakeup(wait_t *);
void wait_destroy(wait_t *);

#ifdef __cplusplus
};
#endif

#endif //__WAIT_H__

